package com.yuyou.train.user.vo.req;

import com.yuyou.train.util.bean.ResBoolSimpleInfo;


public class ReqBehaviorVideo {

	private double duration;

	public double getDuration() {
		return duration;
	}

	public void setDuration(double duration) {
		this.duration = duration;
	}
	
	public static ResBoolSimpleInfo<String> validate(ReqBehaviorVideo req){
		ResBoolSimpleInfo<String> res=new ResBoolSimpleInfo<String>();
		if(req==null){
			res.setSuccess(false);
			res.setMessage("video不能为空");
			return res;
		}
		else if(req.getDuration()<0){
			res.setSuccess(false);
			res.setMessage("时长不能少于0");
			return res;
		}
		return ResBoolSimpleInfo.getSuccessInfo();
	}
	
}
